import { Column, DeleteDateColumn, Entity, PrimaryColumn } from "typeorm";

@Entity("at_comment")
export class CommentEntity {
  @PrimaryColumn({ type: "uuid", generated: "uuid" })
  id: string;

  @Column({ type: "uuid", name: "user_id" })
  userId: string;

  @Column({ type: "varchar", name: "content" })
  content: string;

  @Column({ type: "uuid", name: "task" })
  task: string;

  @Column({ type: "jsonb", name: "attachment" })
  attachment: string;

  @Column({ type: "timestamptz", name: "created_at" })
  createdAt: Date;

  @Column({ type: "varchar", name: "created_by" })
  createdBy: string;

  @Column({ type: "timestamptz", name: "updated_at" })
  updatedAt: Date;

  @Column({ type: "varchar", name: "updated_by" })
  updatedBy: string;

  @DeleteDateColumn({name: "deleted_at"})  deletedAt: Date;
}
